package com.demo.provider;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * 通过SpringMVC暴露http访问接口
 */
@RestController
@RequestMapping(value = "/api/provider")
public class DubboApi {
    @Resource
    private IDubboProvider dubboProvider;

    @GetMapping("/getAppName")
    public String getAppName() {
        return dubboProvider.getAppName();
    }
}
